package cn.dy.service.impl;

import cn.dy.dao.EmpDao;
import cn.dy.dao.impl.EmpDaoImpl;
import cn.dy.pojo.Emp;
import cn.dy.service.EmpService;

import java.util.List;

public class EmpServiceImpl implements EmpService {
    private EmpDao empDao=new EmpDaoImpl();
    @Override
    public List<Emp> selectAll(){
        return empDao.selectAll();
    }

    @Override
    public Emp selectById(int id) {
        return empDao.selectById(id);
    }

    @Override
    public void add(Emp emp) {
        empDao.add(emp);
    }

    @Override
    public void delete(int id) {
        empDao.delete(id);
    }

    @Override
    public void update(Emp emo) {
        empDao.update(emo);
    }
}
